<template>
  <div>
    <h2>{{ count }}</h2>
    <button @click="add(2)">+1</button>
    <button @click="reduce(2)">-1</button>
  </div>
</template>

<script>
export default {
  data() {
    return {
      count: 0,
    };
  },
  methods: {
    add(num) {
      this.count += num;
    },
    reduce(num2) {
      this.count -= num2;
    },
  },
};
</script>

<style>
</style>